package com.example.listener;

import com.example.event.GenericEvent;
import org.springframework.context.ApplicationListener;
import org.springframework.stereotype.Component;

@Component
public class StringEventListener implements ApplicationListener<GenericEvent<String>> {

    @Override
    public void onApplicationEvent(GenericEvent<String> event) {
        System.out.println("Received generic event - " + event.getContent());
    }
}